<?php

namespace Home\Model;
use Think\Model\RelationModel;
class LendinglistModel extends RelationModel {
	
	
	    protected $_link = array(
        'User'=>array(
            'mapping_type'      => self::BELONGS_TO,
            'class_name'        => 'User',
			'foreign_key'   => 'userid',
			'as_fields' => 'username',
            ),
		'In'=>array(
            'mapping_type'      => self::BELONGS_TO,
            'class_name'        => 'Instrument',
			'foreign_key'   => 'inid',
			'as_fields' => 'inum,iname',
            ),
        );
	
}
	
	
	



?>